<template>
  <div id="app">
    <keep-alive>
      <router-view v-if="$route.meta.keepAlive">
        <!-- 这里是会被缓存的视图组件，比如NewsList -->
      </router-view>
    </keep-alive>

    <router-view v-if="$route.meta && !$route.meta.keepAlive">
      <!-- 这里是不被缓存的视图组件，比如NewsDetail -->
    </router-view>
  </div>
</template>

<style>
</style>
